/**
 * "Visual Paradigm: DO NOT MODIFY THIS FILE!"
 * 
 * This is an automatic generated file. It will be regenerated every time 
 * you generate persistence class.
 * 
 * Modifying its content may cause the program not work, or your work may lost.
 */

/**
 * Licensee: VP Development
 * License Type: Purchased
 */
using System;
using System.Collections;
using Orm.Criteria;
using Orm;
using NHibernate;

namespace petshop {
	public class StaffCriteria : AbstractORMCriteria {
		private StringExpression _name;
		public StringExpression Name {
			get {
				return  _name;
			}
			
		}
		
		private Int32Expression _ID;
		public Int32Expression ID {
			get {
				return  _ID;
			}
			
		}
		
		public StaffCriteria(ICriteria criteria) : base(criteria) {
			_name =  new StringExpression("Name", this);
			_ID =  new Int32Expression("ID", this);
		}
		
		public StaffCriteria(PersistentSession session) : this(session.CreateCriteria(typeof(Staff))) {
		}
		
		public StaffCriteria() : this(global::petshop.PetShopPersistentManager.Instance().GetSession()) {
		}
		
		public TransactionCriteria CreateTransactionCriteria() {
			return new TransactionCriteria(CreateCriteria("transaction"));
		}
		
		public Staff UniqueStaff() {
			return (Staff)base.UniqueResult();
		}
		
		public Staff[] ListStaff() {
			IList lList = base.List();
			Staff[] lValues = new Staff[lList.Count];
			lList.CopyTo(lValues, 0);
			return lValues;
		}
		
	}
	
}

